<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>iframe2</title>
    <script type="text/javascript" src="../js/jquery-1.4.4.min.js"></script>
    <script type="text/javascript">

        function frame2_func(){
            //调用frame1_func
            $(window.parent.document).contents().find("#frame1")[0].contentWindow.frame1_func();
        }
    </script>
</head>

<body>
    <h1>这是iframe2</h1><br>
    <button id="clickMe" onclick="frame2_func()">点击我调用frame1方法</button>
</body>
</html>